	@include('admin.head')
	<div class="container">
		<div class="row">
			@include('admin.side')
			<div class="col-md-10" id="content-wrapper">

				<div class="row">
					<div class="col-xs-12">
						<div class="main-box clearfix">
							<div class="clearfix">
								<h2 class="pull-left">技术详细</h2>
							</div>
							<div class="panel panel-default">
								<div class="panel-body">
								  	<div class="row">
								  		<!-- <div class="col-xs-12">
								  			<button class="btn btn-primary pull_right" pid="" id="doEdit"><i class="fa fa-pencil-square-o"></i> 编辑</button>
								  		</div> -->
								  	</div>
								  	<div class="form-horizontal">
								  		<div class="form-group">
								  			<label class="col-xs-4 control-label no_padding_top ">技术名称:</label>
								  			<div class="col-xs-5 uc_value _left" id="tech_name">
								  			</div>
								  		</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">技术开发者:</label>
											<div class="col-xs-5 uc_value _left" id="developer">
											</div>
										</div>
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">技术优势:</label>
											<div class="col-xs-5 uc_value _left" id="advantage_des">
											</div>
										</div>
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">技术原理:</label>
											<div class="col-xs-5 uc_value _left" id="theory_des">
											</div>
										</div>
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">应用领域:</label>
											<div class="col-xs-5 uc_value _left" id="domain">
											</div>
										</div>
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">应用技术:</label>
											<div class="col-xs-5 uc_value _left" id="tech">
											</div>
										</div>


										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">应用主体:</label>
											<div class="col-xs-5 uc_value _left" id="mainbody">

											</div>
										</div>

										<div class="form-group">
											<label class="col-md-4 control-label">技术图标:</label>
											<div class="col-md-5 uc_value no_padding_left" >
												<img id="image" src="" width="100">
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">技术评价:</label>
											<div class="col-xs-5 uc_value _left" id="score">
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">典型客户:</label>
											<div class="col-xs-5 uc_value _left" id="typical_client">
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">节能效率:</label>
											<div class="col-xs-5 uc_value _left" id="efficiency">
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">技术描述:</label>
											<div class="col-xs-5 uc_value _left" id="description">
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">技术原理和概况:</label>
											<div class="col-xs-5 uc_value _left" id="theory">
											</div>
										</div>
								        <div class="form-group">
						    	      		<label for="select" class="col-xs-4 control-label no_padding_right">审核状态:</label>
						    		      	<div class="col-xs-2">
						    		        <select class="form-control input_size" name="verify_state">
						    		          <option value="0">待审核</option>
						    		          <option value="1">审核通过</option>
						    		          <option value="2">审核不通过</option>
						    		        </select>
						    		      </div>
						    		      <div class="col-xs-3 no_padding_both">
						    		      	<button class="btn btn-primary" id="audit">提交</button>
						    		      </div>
						    	    	</div>
									</div>
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>

	@include("admin.footer")
	@include("admin.common")
</body>
<script type="text/javascript">
var tid = "<%Input::get('tid')%>";
$.get("edit_tech/get_tech", {tid : tid}, function (data){
	if(data.success)
	{
		$("#tech_name").html(data.tech_name);
		$("#developer").html(data.developer);
		$("#advantage_des").html(data.advantage_des);
		$("#theory_des").html(data.theory_des);
		$("#score").html(data.score);
		$("#typical_client").html(data.typical_client);
		$("#efficiency").html(data.efficiency);
		$("#description").html(data.description);
		$("#theory").html(decodeURIComponent(data.tech_name));
		$("#tech").html(data.tech_tech.tech.cate_name);
		$("#domain").html(data.tech_domain.domain.parent.cate_name + " "+ data.tech_domain.domain.cate_name);
		$.each(data.mainbody, function(k, v){
			$("#mainbody").append(v.mainbody.name + " ");
		})
		$("#image").attr("src", "<%url('images')%>/"+data.uid+"/<%env('TECH_DIR')%>/"+data.image);

		$("select[name='verify_state']").val(data.verify_state);

	}
})

$("#audit").click(function(){
	var state = $("select[name='verify_state']").val();
	$.post("tech_audit", {tid : tid, state : state}, function (data){
		if(data.success)
		{
			success("", "修改成功");
			setTimeout(function(){
				window.location.href="../tech";
			}, 2000)
		}
	})
})

</script>

</html>